/*
 * @Description:
 * @Version: V1.0.0
 * @Author: 周艳凯 484894717@qq.com
 * @Date: 2024-10-28 14:23:57
 * @LastEditors: 周艳凯 484894717@qq.com
 * @LastEditTime: 2024-10-28 14:28:11
 * @FilePath: props.ts
 * Copyright 2024 Marvin, All Rights Reserved.
 * 2024-10-28 14:23:57
 */
// import { loadingProps } from '../loading';
// import { defineListenerProp } from '../utils/components';
import { type ButtonHTMLAttributes, type PropType } from 'vue';

export type ButtonType = 'default' | 'primary' | 'info' | 'success' | 'warning' | 'danger';

export type ButtonSize = 'normal' | 'mini' | 'small' | 'large';

export const props = {
  type: String as PropType<ButtonType>,
  nativeType: {
    type: String as PropType<ButtonHTMLAttributes['type']>,
    default: 'button',
  },
  size: String as PropType<ButtonSize>,
  loading: Boolean,
  round: Boolean,
  block: Boolean,
  text: Boolean,
  outline: Boolean,
  disabled: Boolean,
  autoLoading: Boolean,
  iconContainer: Boolean,
  ripple: {
    type: Boolean,
    default: true,
  },
  focusable: {
    type: Boolean,
    default: true,
  },
  color: String,
  textColor: String,
  elevation: {
    type: [Boolean, Number, String],
    default: true,
  },
  loadingRadius: [Number, String],
  //   loadingType: pickProps(loadingProps, 'type'),
  //   loadingSize: {
  //     ...pickProps(loadingProps, 'size'),
  //     default: undefined,
  //   },
  //   loadingColor: {
  //     ...pickProps(loadingProps, 'color'),
  //     default: 'currentColor',
  //   },
  onClick: Function as PropType<(event: MouseEvent) => void>,
  onTouchstart: Function as PropType<(event: MouseEvent) => void>,
};
